package com.simple.rpc.registry.zookeeper;

import com.simple.rpc.component.registry.Registry;
import com.simple.rpc.config.ApplicationConfig;
import com.simple.rpc.config.ServiceConfig;

import java.util.Map;

/**
 * simple-rpc/services/接口名:接口版本/服务提供者的ip:host
 *
 * @author mhh
 * @since 2020/9/18
 */
public class ZookeeperRegistry implements Registry {

    @Override
    public void registry(ServiceConfig serviceConfig) {
        System.out.println("注册到zk");
    }

    @Override
    public void subscribe(ServiceConfig serviceConfig) {
        System.out.println("订阅服务变动");
    }

    @Override
    public Map<String, ApplicationConfig> getProviders(ServiceConfig serviceConfig) {
        System.out.println("获取服务列表");
        return null;
    }

    @Override
    public void offline(ServiceConfig serviceConfig) {
        System.out.println("服务下线");
    }
}
